package com.code.demo.mvp.model;

import com.code.demo.mvp.base.OkgoStringCallback;
import com.code.demo.mvp.contract.FakeContract;
import com.lzy.okgo.OkGo;

/**
 * Created by yangliguo on 2019/3/1.
 */

public class FakeModel implements FakeContract.FakeModel {

    @Override
    public void getUsers(OkgoStringCallback callback) {
        OkGo.<String>get("http://jsonplaceholder.typicode.com/users")//
                .execute(callback);
    }

    @Override
    public void getTodo(OkgoStringCallback callback) {
        OkGo.<String>get("https://jsonplaceholder.typicode.com/todos/1")//
                .execute(callback);
    }
}
